<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>

    <script src="https://unpkg.com/vue"></script>
    <link href="https://cdn.bootcss.com/iview/2.2.0/styles/iview.css" rel="stylesheet">

    <script src="https://cdn.bootcss.com/iview/2.2.0/locale/zh-CN.js"></script>
    <script src="https://cdn.bootcss.com/iview/2.2.0/iview.min.js"></script>

</head>

<body>
    <div id="testOne">

        <i-button @click="show">Click me!</i-button>
        <Modal v-model="visible" title="Welcome">欢迎使用 iView</Modal>

        <i-Button>默认</i-Button>
        <Card>
            <p slot='title'>测试分享按钮事件</p>
            <p>
                <i-button type='primary' v-on:click="shareQQ">
                    <Icon type="share"></Icon>
                    分享QQ空间</i-button>
            </p>
            <p>
                <i-button type='success' v-on:click="shareSina">
                    <Icon type="share"></Icon>
                    分享新浪微博
                </i-button>
            </p>
            <p>卡片内容</p>
        </Card>
        <Collapse accordion>
            <Panel name="1">
                面板1
                <p slot="content">中文内容</p>
            </Panel>
            <Panel name="2">
                面板2
                <p slot="content">中文内容2</p>
            </Panel>
        </Collapse>
    </div>

    <script src="../js/ShareHelper2.0.js"></script>
    <script>
        new Vue({
            el: '#testOne',
            data: {
                visible: false
            },
            methods: {
                show: function () {
                    this.visible = !this.visible;
                },
                //分享QQ空间
                shareQQ: function () {
                    shareHelper.qzoneShare('http://www.gongjuji.net', '微工具集', 'http://www.gongjuji.net/Content/Images/convertogif.png');
                },
                //分享新浪
                shareSina:function(){
                    shareHelper.sinaShare('http://movie.tianma3798.cn/', '观影者', 'http://www.cbooo.cn/moviepic/229733.jpg');
                }
            }
        });
    </script>

</body>

</html>